import org.openqa.selenium.WebDriver;
import org.openqa.selenium.WebElement;
import org.openqa.selenium.support.FindBy;


public class LoginPage extends Page {
	
	@FindBy(name="login")
	private WebElement loginField;
	
	@FindBy(name="password")
	private WebElement passwordField;
	
	@FindBy(name="commit")
	private WebElement comminBtn;

	public LoginPage(WebDriver driver) {
		super(driver);
	}

	public void open() {
		driver.get("url");
	}

	public SprintBacklogPage logIn(String login, String pass) {
		loginField.sendKeys(login);
		passwordField.sendKeys(pass);
		comminBtn.click();
		
		return new SprintBacklogPage();
	}

}
